package com.elitel.common;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;


public class DateUtilFormat{

	
	public static String dataToString(Date date){
		return new SimpleDateFormat("yyyy:MM:dd:HH:mm").format(new Date());
	}
	
	public static Date stringToDate(Date date){
		Date aDate = null;
		try {
			aDate =  new SimpleDateFormat("yyyy:MM:dd:HH:mm").parse(new SimpleDateFormat("yyyy:MM:dd:HH:mm").format(new Date()));
		} catch (ParseException e) {
			e.printStackTrace();
		}
		return aDate;
	}
}
